package designpattern.builder.base;

/**
 * 指挥者。
 * 
 * @author chunwei.zhao
 *
 */
public class Director {

	// 建造者；
	private Builder builder;

	public Director(Builder builder) {
		super();
		this.builder = builder;
	}

	/**
	 * 构造产品。
	 * 
	 * @return 产品。
	 */
	public Product construct() {
		builder.buildPart();
		return builder.getResult();
	}

}
